﻿using System;
using System.Windows.Controls;
using System.Windows.Data;

namespace XDCCManager.Converters
{
	class BooleanToReverseVisibilityConverter : IValueConverter
	{
		BooleanToVisibilityConverter converter = new BooleanToVisibilityConverter();
		#region IValueConverter Members

		public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
		{
			return converter.Convert(!(bool)value, targetType, parameter, culture);
		}

		public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
		{
			return !(bool)converter.ConvertBack(value, targetType, parameter, culture);
		}

		#endregion
	}
}
